import Vue from 'vue'
import App from './App'
import "@/static/css/rule.css";
import "@/static/css/public.css"

import common from './utils/common.js'
import http from './utils/http.js'
import api from './utils/api.js'

// console.log('xxxxx',http.publicJson)

// Vue.prototype.$api = api;
// Vue.prototype.$http = http.publicRequest;


Vue.config.productionTip = false

App.mpType = 'app'

const msg = (title, duration=1500, mask=false, icon='none')=>{
	//统一提示方便全局修改
	if(Boolean(title) === false){
		return;
	}
	uni.showToast({
		title,
		duration,
		mask,
		icon
	});
}

import cuCustom from './colorui/components/cu-custom.vue'
Vue.component('cu-custom',cuCustom)

Vue.prototype.$message = {msg};

Vue.prototype.$api = api
Vue.prototype.$http = http.publicRequest;
Vue.prototype.$Json = http.publicJson;
Vue.prototype.$common = common;

const app = new Vue({
    ...App
})
app.$mount()
